import request from '@/utils/request'

export function list(params) {
  return request({
    url: '/api/system/dept/list',
    method: 'post',
    data: params || {}
  })
}

export function add(data) {
  return request({
    url: '/api/system/dept/create',
    method: 'post',
    data
  })
}

export function update(data) {
  return request({
    url: '/api/system/dept/update',
    method: 'post',
    data
  })
}

export function batchDel(ids) {
  return request({
    url: '/api/system/dept/delete',
    method: 'post',
    data: {'ids': ids}
  })
}
